home *** CD-ROM | disk | FTP | other *** search
/ Internet Info 1994 March / Internet Info CD-ROM (Walnut Creek) (March 1994).iso / inet / internet-drafts / draft-ietf-tn3270e-current-pract-01.txt < prev    next >
Text File  |  1993-09-28  |  23KB  |  581 lines

  1.  
  2.  
  3. TN3270 Enhancements Working Group                           Jon Penner
  4. draft-ietf-tn3270e-current-pract-01.txt                   October 1993
  5.  
  6.                         TN3270 Current Practices
  7.  
  8.  
  9. Status of this Memo
  10.  
  11.    This document is an Internet Draft.  Internet Drafts are working
  12.    documents of the Internet Engineering Task Force (IETF), its Areas,
  13.    and its Working Groups.  Note that other groups may also distribute
  14.    working documents as Internet Drafts.
  15.  
  16.    Internet Drafts are draft documents valid for a maximum of six
  17.    months.  Internet Drafts may be updated, replaced, or obsoleted by
  18.    other documents at any time.  It is not appropriate to use Internet
  19.    Drafts as reference material or to cite them other than as a
  20.    "working draft" or "work in progress."
  21.  
  22.    Please check the 1id-abstracts.txt listing contained in the
  23.    internet-drafts Shadow Directories on ds.internic.net,
  24.    nic.nordu.net, ftp.nisc.sri.com, or munnari.oz.au to learn the
  25.    current status of any Internet Draft.
  26.  
  27. Abstract
  28.  
  29.    This document describes the existing implementation of transferring
  30.    3270 display terminal data using currently available telnet
  31.    capabilities.   The name traditionally associated with this
  32.    implementation is TN3270.
  33.  
  34.    Information is provided to aid in the implementation of TN3270
  35.    servers as well as client terminal emulators.
  36.  
  37.    The following areas pertaining to TN3270 implementations are
  38.    covered in this document:
  39.  
  40.    1. the telnet options negotiated to transition from a NVT ASCII
  41.    state to a TN3270 state ready to process incoming 3270 data stream
  42.    commands
  43.  
  44.    2. the method for sending and receiving 3270 data
  45.  
  46.    3. the method of handling some special keys known as SYSREQ and
  47.    ATTN using current available telnet commands.
  48.  
  49.    4. the events that will transition a TN3270 session back to an NVT
  50.    session
  51.  
  52.  
  53. Motivation
  54.  
  55.    3270 display terminal data differs from traditional display terminal
  56.    data in that it is block mode and uses EBCDIC instead of ASCII
  57.    character representation. These two differences are the primary
  58.  
  59. J. Penner                Expires February 1994                [Page 1]
  60.  
  61. TN3270 Enhancements Working Group                           Jon Penner
  62. Internet Draft                                            October 1993
  63.  
  64.    reason for the differentiation of TN3270 from standard Telnet in
  65.    this document.
  66.  
  67.  
  68. Background
  69.  
  70.    Existing proprietary IBM networks are not easily integrated with
  71.    the increasing number of multi-platform networking environments,
  72.    specifically TCP/IP. These proprietary IBM networks are referred to
  73.    as SNA (Systems Network Architecture) in this document. To address
  74.    this issue, several vendors have introduced telnet servers that
  75.    provide a TCP/IP users a connection to existing IBM mainframes by
  76.    supporting display terminal emulation using a subset of the existing
  77.    telnet protocol. IBM now also offers host based tn3270 support over
  78.    TCP/IP.
  79.  
  80.    IBM terminals are generically referred to as 3270's which
  81.    includes a broad range of terminals and devices, not all of which
  82.    actually begin with the numbers 327x.
  83.  
  84.    3270 terminals in the IBM SNA network environment have 2 parallel
  85.    sessions with the host computer. One is used for communicating with
  86.    the host application, the other is used for communicating with the
  87.    network control program that links the terminal with the
  88.    appropriate host computer.  For the purposes of TN3270, this
  89.    distinction is not apparent or relevant since there is actually
  90.    only a single telnet session with the host computer or server.  On
  91.    an IBM SNA network, the 3270 terminal has a special key that toggles
  92.    between the two sessions (SYSREQ).  A brief discussion on how
  93.    some telnet servers deal with this is included.
  94.  
  95.    In an SNA environment, a client session is identified by a Logical
  96.    Unit (LU) name.  In a non-SNA environment, there is not a LU name
  97.    associated with a client session.  The closest thing to a LU name
  98.    in the TN3270 environment is the client's IP address.  Although some
  99.    telnet servers are connected to the host using SNA, tn3270 clients
  100.    using these servers have no defined way to determine the LU name
  101.    associated with the session.
  102.  
  103.    Currently, support for 3270 terminal emulation over Telnet is
  104.    accomplished by the de facto standard of negotiating three separate
  105.    Telnet Options - Terminal-Type [2], Binary Transmission [3], and
  106.    End of Record [4].  This negotiation and the resulting data flow will
  107.    be described below.
  108.  
  109.    RFC 1041 [1] attempted to standardize the method of negotiating
  110.    3270 terminal support by defining the 3270 Regime Telnet Option.
  111.    Historically, very few developers and vendors ever implemented
  112.    RFC 1041.
  113.  
  114.    All references in this document to the 3270 datastream, SNA versus
  115.    non-SNA operation, 3270 datastream commands, orders, structured
  116.  
  117. J. Penner                Expires February 1994                [Page 2]
  118.  
  119. TN3270 Enhancements Working Group                           Jon Penner
  120. Internet Draft                                            October 1993
  121.  
  122.    fields and the like rely on [6].
  123.  
  124.    References to SNA Request and Response Units rely on [7].
  125.  
  126.    TN3270 does not support typical SNA responses and is classified as a
  127.    non-SNA protocol.  A TN3270 emulator is not aware or concerned about
  128.    how the telnet server is connected to a 3270 host application.
  129.    Current telnet server implementations are either 3270 host based or
  130.    connected to the host using the SNA protocol.
  131.  
  132.    NOTE: Except where otherwise stated, this document does not
  133.    distinguish between telnet servers that represent SNA devices and
  134.    those that represent non-SNA 3270 devices.
  135.  
  136.    Some typical "SNA" functions such as the SYSREQ
  137.    and ATTN keys have been mapped to existing telnet function codes
  138.    and are supported by some telnet server implementations.
  139.  
  140.    There are several shortcomings in current tn3270 implementations;
  141.    among them are the following:
  142.  
  143.     - It provides no capability for Telnet clients to emulate the 328x
  144.       class of printers.
  145.  
  146.     - There is no mechanism by which a Telnet client can request that
  147.       a connection be associated with a given 3270 device-name.  This
  148.       can be of importance when a terminal session is being
  149.       established, since many host applications behave differently
  150.       depending on the network name of the terminal.  In the case of
  151.       printer emulation, this capability is an absolute necessity
  152.       because a large number of host applications have some method of
  153.       pre-defining printer destinations.
  154.  
  155.     - The 3270 ATTN and SYSREQ keys are not universally supported.
  156.  
  157.     - There is no support for the SNA positive/negative response
  158.       process. All data that is sent is assumed to either be handled
  159.       or ignored.
  160.       A negative response indicates some sort of error at the client
  161.       while processing the previously received data; this could be
  162.       caused by the host application building a 3270 datastream that
  163.       contains an invalid command, or by a mechanical error at the
  164.       client side, among other things.
  165.       Positive responses indicate processing of the previously received
  166.       data has completed.
  167.  
  168.     - There is no mechanism by which the client can access the SNA
  169.       BIND information.  The BIND image in a SNA environment
  170.       contains a detailed description of the session between the
  171.       telnet server and the host application.
  172.  
  173.     - The connection negotiation does not make it clear whether clients
  174.  
  175. J. Penner                Expires February 1994                [Page 3]
  176.  
  177. TN3270 Enhancements Working Group                           Jon Penner
  178. Internet Draft                                            October 1993
  179.  
  180.       should support 3270 structured fields.
  181.  
  182.  
  183.  
  184. Command Names and Codes
  185.  
  186.    TN3270 makes use of existing Telnet commands and codes and does
  187.    not define any new commands.
  188.  
  189.        BINARY            0
  190.        TERMINAL-TYPE    24
  191.        EOR              25
  192.  
  193.    Additional commands may be used during a TN3270 session and are
  194.    interpreted as per their respective RFCs. Examples of this are
  195.    [1] 3270-REGIME, [8] SUPPRESS-GO-AHEAD, [9] ECHO
  196.    and [10] TIMING-MARK.
  197.  
  198.  
  199.  
  200. Command Meanings
  201.  
  202.    See respective RFCs.
  203.  
  204.  
  205. Connection Negotiation
  206.  
  207.    The following example shows a TN3270-capable server and a
  208.    tn3270 client establishing a connection:
  209.  
  210.  
  211.    The TCP/IP port generally used to connect with is 23 (Telnet).
  212.  
  213.    At any place before and during the tn3270 connection negotiation
  214.    process, other telnet commands and data may be transferred and
  215.    will be interpreted under the existing telnet state. Some existing
  216.    tn3270 servers start a client connection using an NVT telnet
  217.    dialog to establish parameters needed to complete the tn3270
  218.    connection to the desired host.
  219.  
  220.    The order of negotiating terminal type, EOR and BINARY is not
  221.    significant, this example shows a typical tn3270 connection.
  222.  
  223.       Server:  IAC DO TERMINAL-TYPE
  224.  
  225.       Client:  IAC WILL TERMINAL-TYPE
  226.  
  227.       Server:  IAC SB TERMINAL-TYPE SEND IAC SE
  228.  
  229.       Client:  IAC SB TERMINAL-TYPE IS <terminal type>IAC SE
  230.  
  231. J. Penner                Expires February 1994                [Page 4]
  232.  
  233. TN3270 Enhancements Working Group                           Jon Penner
  234. Internet Draft                                            October 1993
  235.  
  236.  
  237.        where <terminal type> is a string consisting of terminal model,
  238.      type and support of enhanced attribute bytes; and example is
  239.      IBM-3278-2.  The acceptable values are listed in RFC 1340,
  240.      Assigned Numbers [5].  Other values are in use that do not exist
  241.      in [5].
  242.    
  243.      The -2 following 3278 designates the alternate screen size.
  244.      3270 terminals have the ability to switch between the
  245.      standard (24x80) screen size and an alternate screen size.
  246.      Model -2 is 24x80 which is the same as the standard size.
  247.      Model -3 is 32x80, model -4 is 43x80 and model -5 is 27x132.
  248.  
  249.      Appending the two character string "-E" to the end of the
  250.      terminal type signifies that the terminal is capable of handling
  251.      3270 extended data stream. This is interpreted to mean that the
  252.      terminal is able to handle structured fields, which are
  253.      described below.  Some telnet server implementations also
  254.      interpret this to mean that the terminal is capable of handling
  255.      extended attributes (highlighting, field validation, character
  256.      set, outlining, etc.) [6].
  257.  
  258.      The 3279 series of terminals is capable of extended attributes
  259.      while the 3278 series is not.
  260.  
  261.       Server:  IAC DO EOR IAC WILL EOR
  262.       Client:  IAC WILL EOR IAC DO EOR
  263.       Server:  IAC DO BINARY IAC WILL BINARY
  264.       Client:  IAC WILL BINARY IAC DO BINARY
  265.       Server:  <3270 data stream>
  266.       Client:  <3270 data stream>
  267.            .            .
  268.            .            .
  269.  
  270.    To terminate the connection the socket is closed by one of
  271.    the session partners. Typically, when the user logs off of the
  272.    host, the telnet server closes the connection.
  273.  
  274.    If the telnet server wishes to go back to NVT mode, it may issue
  275.    the following commands:
  276.  
  277.        Server:  IAC WONT BINARY
  278.        Client:  IAC DONT BINARY
  279.  
  280.            or
  281.  
  282.        Server:  IAC WONT EOR
  283.        Client:  IAC DONT EOR
  284.  
  285.    Either one of the above two cases causes the connection to not
  286.    satisfy the requirements for a valid TN3270 session. The telnet
  287.    client should then process data from the server as though it
  288.  
  289. J. Penner                Expires February 1994                [Page 5]
  290.  
  291. TN3270 Enhancements Working Group                           Jon Penner
  292. Internet Draft                                            October 1993
  293.  
  294.    were NVT ASCII data.
  295.  
  296.    The following examples show how a TN3270 client handles
  297.    the 3270-REGIME, SUPPRESS-GO-AHEAD, ECHO and TM commands.
  298.  
  299.    Very few servers support the 3270 Regime Telnet Option.
  300.    If the client does not support this option and responds negatively
  301.    as shown in the following example, the server will proceed on to
  302.    the more typical example shown above.
  303.  
  304.       Server:  IAC DO 3270-REGIME
  305.       Client:  IAC WONT 3270-REGIME
  306.        Normal negotiation:
  307.       Server:  IAC DO TERMINAL-TYPE
  308.          ...  (see above)
  309.  
  310.    The Suppress Go Ahead option [8] is requested by some servers. The
  311.    Suppress Go Ahead option RFC lists the default as being go aheads
  312.    are transmitted to signal the receiver to begin transmitting.
  313.    Since TN3270 negotiates binary and end-of-record and is a block
  314.    mode protocol, the telnet go ahead character is not sent.
  315.    Most servers do not negotiate this option even though they do not
  316.    use the telnet go ahead character.
  317.  
  318.       Server:  IAC DO SUPPRESS-GO-AHEAD
  319.       Client:  IAC WILL SUPPESS-GO-AHEAD
  320.  
  321.    The Echo option [9] is negotiated by those servers that make use
  322.    of the telnet NVT mode to allow the user to enter information
  323.    prior to negotiating the options necessary for TN3270.  This
  324.    information includes but is not limited to user identification,
  325.    password and destination 3270 host.  Some servers accept the
  326.    default for this option which is for the client to not do a local
  327.    echo of characters the user enters at the keyboard. This allows
  328.    the server to decide if it should echo characters back to the
  329.    client (or not in the case of password). Echoing characters back
  330.    to the client causes slow response time since every character is
  331.    typically echoed individually. Because of this, some servers
  332.    negotiate for the client to do it's own local echoing (except
  333.    for passwords). The following example illustrates this case.
  334.  
  335.       Server:  IAC DO ECHO
  336.       Client:  IAC WILL ECHO
  337.         (Client does local display of all characters)
  338.       Server:  IAC WONT ECHO
  339.       Client:  IAC DONT ECHO
  340.         (Client enters password - not locally displayed or remotely
  341.       echoed)
  342.       Server:  IAC DO ECHO
  343.       Client:  IAC WILL ECHO
  344.      (Client resumes local display of all characters)
  345.  
  346.  
  347. J. Penner                Expires February 1994                [Page 6]
  348.  
  349. TN3270 Enhancements Working Group                           Jon Penner
  350. Internet Draft                                            October 1993
  351.  
  352.    The Timing Mark option [10] is used by some servers to test for
  353.    the continued presence of an TN3270 client. The following example
  354.    will assure the server the client is still alive.
  355.  
  356.       Server:  IAC DO TIMING-MARK
  357.       Client:  IAC WONT TIMING-MARK
  358.  
  359.  
  360.  
  361. Handling 3270 data
  362.  
  363.    The 3270 data stream consists of a command and its associated data.
  364.    Commands include but are not limited to erase screen, erase and write
  365.    to screen and read current screen; see [6] for a complete description
  366.    of 3270 commands and parameters.
  367.  
  368.    The reason for negotiating the EOR telnet option [4] is to provide a
  369.    method for separating these commands since no length information is
  370.    specified. 3270 commands are interpreted by the telnet client in
  371.    their entirety.  Each 3270 command and possible data is terminated
  372.    with the IAC EOR sequence.
  373.  
  374.    The Binary option [3] is also required since 3270 data may contain
  375.    the FF (hexadecimal) or IAC character. When this character is
  376.    encountered during a tn3270 connection it is handled as per the
  377.    Binary RFC [3].
  378.  
  379. 3270 Structured Fields
  380.  
  381.    3270 structured fields provide a much wider range of features than
  382.    "old-style" 3270 data, such as support for graphics, partitions and
  383.    IPDS printer datastreams. A structured field is a 3270 data type
  384.    that allows non 3270 data to be embedded within 3270 data. Briefly,
  385.    a structured field consists of the structured field command followed
  386.    by one or more data blocks. Each data block has a length and a
  387.    structured field identifier, followed optionally by additional data.
  388.  
  389.    Not every TN3270 client can be expected to support all structured
  390.    field functions.   There must be a  mechanism by which those clients
  391.    that are capable of supporting some or all structured field
  392.    functions can indicate their wishes. This is typically done by
  393.    adding "-E" to the end of the terminal type string. That is, when the
  394.    terminal identifies itself as being able to handle extended
  395.    attributes, it also is capable of being able to send and receive
  396.    structured fields.
  397.  
  398.    The design of 3270 structured fields provides a convenient means to
  399.    convey the level of support (including no support) for the various
  400.    structured field functions.  This mechanism is the Read Partition
  401.    Query command, which is sent from the host application to the
  402.    client.  The client responds with a Query Reply, listing which,
  403.    if any, structured field functions it supports.
  404.  
  405. J. Penner                Expires February 1994                [Page 7]
  406.  
  407. TN3270 Enhancements Working Group                           Jon Penner
  408. Internet Draft                                            October 1993
  409.  
  410.  
  411.    A TN3270 client that supports structured fields will
  412.    respond to a Read Partition Query command with the appropriate reply.
  413.    The sequence of events of when a client receives a Read Partition
  414.    Query and it does not support structured fields is left up to the
  415.    client implementation.  Typically clients can identify at least this
  416.    structured field and reply with a null set.
  417.  
  418.  
  419. Implementation Rules
  420.  
  421.    All commands and parameters are governed by their respective RFCs
  422.  
  423.  
  424. The 3270 ATTN (Attention) Key
  425.  
  426.    The 3270 ATTN key is interpreted by many host applications in an
  427.    SNA environment as an indication that the user wishes to interrupt
  428.    the execution of the current process.  A majority of the telnet
  429.    servers currently accept the telnet IAC BREAK (code 243) sequence to
  430.    signal this event.
  431.  
  432.    Use of this key requires two things:
  433.  
  434.     - TN3270 clients should provide as part of their keyboard
  435.       mapping a single key or a combination of keys that map to
  436.       the 3270 ATTN key.  When the user presses this key(s), the
  437.       client should transmit a Telnet BREAK command to the server.
  438.  
  439.     - TN3270 servers should translate the BREAK command received from
  440.       a TN3270 client into the appropriate form and pass it along
  441.       to the host application as an ATTN key.  In other words, the
  442.       server representing an SLU in an SNA session should send
  443.       a SIGNAL RU to the host application.
  444.  
  445.    The ATTN key is not supported in a non-SNA environment; therefore,
  446.    a TN3270 server representing non-SNA 3270 devices should ignore
  447.    any Telnet BREAK commands it receives from a client.
  448.  
  449. The 3270 SYSREQ Key
  450.  
  451.    The 3270 SYSREQ key is useful in an environment where the
  452.    telnet server is attached to the host using SNA. The SYSREQ key
  453.    is useful in this environment when the host application becomes
  454.    locked and the user wishes to terminate the session without
  455.    closing the Telnet connection.
  456.  
  457.    The Telnet Interrupt Process (IP) command is interpreted by some
  458.    telnet servers as a SYSREQ key. Other servers recognize the 3270
  459.    Test Request key as a SYSREQ key.  In an SNA environment, pressing
  460.    this key toggles the terminal between the host application session
  461.    and the network control program session.  Usually the user
  462.  
  463. J. Penner                Expires February 1994                [Page 8]
  464.  
  465. TN3270 Enhancements Working Group                           Jon Penner
  466. Internet Draft                                            October 1993
  467.  
  468.    will enter LOGOFF once this key has been pressed to terminate
  469.    the application session and then select a new host to connect to.
  470.    Sometimes, if SYSREQ is pressed again, the host application will
  471.    become unlocked and normal activities may then proceed.
  472.  
  473.    It is entirely up to the telnet server to interpret this command and
  474.    send the appropriate commands to the host as well as format the
  475.    resulting host data for display on the telnet client. The data
  476.    format during the network control program session is in a slightly
  477.    different format than normal 3270 data. Since the telnet server
  478.    has no way to pass this data directly to the telnet client, it must
  479.    either handle it entirely and ignore SYSREQ events or convert it to
  480.    3270  data to present to the client.  There is no restriction that
  481.    prevents the server from negotiating out of the TN3270 state to
  482.    NVT to present this data.
  483.  
  484.    In order to implement SYSREQ key support, TN3270
  485.    clients should  provide a key (or combination of keys) that is
  486.    identified as mapping to the 3270 SYSREQ key.  When the user presses
  487.    this key(s), the client should either transmit a Telnet IP command
  488.    or Test Request key to the server, depending on the server
  489.    implementation.
  490.  
  491.    TN3270 servers representing non-SNA 3270 terminals may ignore any
  492.    Telnet IP commands or Test Request keys they receive from a client.
  493.  
  494.  
  495. References
  496.  
  497. [1] Rekhter, J., "Telnet 3270 Regime Option", RFC 1041, IBM
  498.     Corporation, January 1988.
  499.  
  500. [2] VanBokkelen, J., "Telnet Terminal-Type Option", RFC 1091,
  501.     FTP Software, Inc., February 1989.
  502.  
  503. [3] Postel, J., and J. Reynolds, "Telnet Binary Transmission",
  504.     RFC 856, USC/Information Sciences Institute, May 1983.
  505.  
  506. [4] Postel, J., "Telnet End of Record Option", RFC 885, USC/
  507.     Information Sciences Institute, December 1983.
  508.  
  509. [5] Reynolds, J., and J. Postel, "Assigned Numbers", RFC 1340,
  510.     USC/Information Sciences Institute, July 1992.
  511.  
  512. [6] "3270 Information Display System - Data Stream Programmer's
  513.     Reference", publication number GA23-0059, IBM Corporation.
  514.  
  515. [7] "Systems Network Architecture - Formats",
  516.     publication number GA27-3136, IBM Corporation.
  517.  
  518. [8] Postel, J., and J. Reynolds, "Telnet Suppress Go Ahead Option",
  519.     RFC 858, USC/Information Sciences Institute, May 1983.
  520.  
  521. J. Penner                Expires February 1994                [Page 9]
  522.  
  523. TN3270 Enhancements Working Group                           Jon Penner
  524. Internet Draft                                            October 1993
  525.  
  526.  
  527. [9] Postel, J., and J. Reynolds, "Telnet Echo Option",
  528.     RFC 857, USC/Information Sciences Institute, May 1983.
  529.  
  530. [10] Postel, J., and J. Reynolds, "Telnet Timing Mark Option",
  531.     RFC 860, USC/Information Sciences Institute, May 1983.
  532.  
  533.  
  534. Author's Note
  535.  
  536.    Portions of this document were drawn from the following sources:
  537.  
  538.     - A White Paper written by Owen Reddecliffe, WRQ Corporation,
  539.       October 1991.
  540.  
  541.     - Experimental work on the part of Cleve Graves and Michelle
  542.       Angel, OpenConnect Systems, 1992 - 1993.
  543.  
  544.     - Discussions at the March 1993 IETF meeting.
  545.  
  546.     - Discussions on the "TN3270E" list, Spring 1993.
  547.  
  548.     - An Internet-draft written by Bill Kelly, Auburn University,
  549.       July, 1993
  550.  
  551.  
  552. Author's Address
  553.  
  554.    Jon Penner
  555.    DCA, Inc.
  556.    2800 Oakmont Drive
  557.    Austin, TX 78664
  558.  
  559.    Phone: (512) 244-3871
  560.  
  561.    Email: jjp@bscs.uucp
  562.  
  563.  
  564.  
  565.  
  566.  
  567.  
  568.  
  569.  
  570.  
  571.  
  572.  
  573.  
  574.  
  575.  
  576.  
  577.  
  578.  
  579. J. Penner                Expires February 1994                [Page 10]
  580.  
  581.